Class CacheItem

Summary

Fully Qualified Name: Laminas\Cache\Psr\CacheItemPool\CacheItem
Implements: CacheItemInterface

Description

Methods

Name Description Defined By
__construct() Constructor. CacheItem
expiresAfter() {@inheritdoc} CacheItem
expiresAt() {@inheritdoc} CacheItem
get() {@inheritdoc} CacheItem
getKey() {@inheritdoc} CacheItem
getTtl() Returns number of seconds until item expires CacheItem
isHit() {@inheritdoc} CacheItem
set() {@inheritdoc} CacheItem
setIsHit() Sets isHit value CacheItem

Method Details

__construct()

Constructor.

Parameter Name Type Description
$key string
$value mixed
$isHit bool

Returns:

expiresAfter()

{@inheritdoc}

Parameter Name Type Description
$time

Returns:

expiresAt()

{@inheritdoc}

Parameter Name Type Description
$expiration

Returns:

get()

{@inheritdoc}

Returns:

getKey()

{@inheritdoc}

Returns:

getTtl()

Returns number of seconds until item expires

If NULL, the pool should use the default TTL for the storage adapter. If <= 0, the item has expired.

Returns: int|null

isHit()

{@inheritdoc}

Returns:

set()

{@inheritdoc}

Parameter Name Type Description
$value

Returns:

setIsHit()

Sets isHit value

This function is called by CacheItemPoolDecorator::saveDeferred() and is not intended for use by other calling code.

Parameter Name Type Description
$isHit bool

Returns: $this

Top